#ifndef __MESSAGE_HPP__ 
#define __MESSAGE_HPP__
#include <string>
#include <vector>
using std::vector;
using std::string;
namespace wd{


//任务类型
enum TaskType{

    //注册类型
    TASK_TYPE_REGISTER1 = 1,
    TASK_TYPE_REGISTER1_RESP_OK,
    TASK_TYPE_REGISTER1_RESP_ERROR,

    TASK_TYPE_REGISTER2 = 4,
    TASK_TYPE_REGISTER2_RESP_OK,
    TASK_TYPE_REGISTER2_RESP_ERROR,


    //登录类型
    TASK_TYPE_LOGIN_SECTION1 = 7,
    TASK_TYPE_LOGIN_SECTION1_RESP_OK,
    TASK_TYPE_LOGIN_SECTION1_RESP_ERROR,

    TASK_TYPE_LOGIN_SECTION2 = 10,
    TASK_TYPE_LOGIN_SECTION2_RESP_OK,
    TASK_TYPE_LOGIN_SECTION2_RESP_ERROR,


    //播放列表
    TASK_TYPE_GET_CAMERALIST = 13,
    TASK_TYPE_GET_CAMERALIST_RESP_0,
    TASK_TYPE_GET_CAMERALIST_RESP_1,
    TASK_TYPE_GET_CAMERALIST_RESP_ERROR,

    //RTSP实时流请求
    TASK_TYPE_GET_PACKET = 17,
    TASK_TYPE_GET_PACKET_OK,
    TASK_TYPE_GET_PACKET_ERROR,

    //客户端录像请求
    TASK_TYPE_GET_VIDEO = 66,
    TASK_TYPE_GET_VIDEO_OK,
    TASK_TYPE_GET_VIDEO_ERROR,

};

struct Packet{
    int     type;
    int     length;
    string  msg;
};


struct TLV{
    int type;
    int length;
    char data[1024];

};

struct TVLPacket
{
    int type;
    int length;
    int camera_id;
    //char * data;
//    vector<char> data;
    string data;
};

};



#endif

